const state = {
  enums: {
    user_type: {}
  },
  config: {}
}

const mutations = {
  SET_ENUMS: (state, value) => {
    for (let i in value) {
      state.enums[i] = value[i]
    }
  },
  SET_CONFIG: (state, value) => {
    state.config = value
  }
}

const actions = {
  setEnums({commit}, data) {
    commit('SET_ENUMS', data)
  },
  setConfig({commit}, data) {
    commit('SET_CONFIG', data)
  }
}

export default {
  namespaced: true,
  state,
  mutations,
  actions
}

